package com.lingnan.tijian.controller;

import com.lingnan.tijian.domain.CheckItem;
import com.lingnan.tijian.domain.result.Result;
import com.lingnan.tijian.service.ICheckItemService;
import org.springframework.beans.factory.annotation.Autowired;

import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

@RestController
@RequestMapping("/checkItem")
public class CheckItemController {
    @Autowired
    private ICheckItemService checkItemService;

    @GetMapping("/{setmealId}")
    public Result<List<CheckItem>> selectCheckItemListBySetmealId(@PathVariable Long setmealId) {
        List<CheckItem> checkItemList = checkItemService.selectCheckItemListBySetmealId(setmealId);
        return Result.success(checkItemList);
    }
}
